package com.anzia.demo07;

/**
 *@ClassName StringBuilder_Demo
 *@Description
 *@Author Anzia.
 *@Date 2021/4/11 18:52
 *@Version 1.0
 **/
public class StringBuilder_Demo {
    public static void main(String[] args) {
        long start = System.currentTimeMillis();
        //String string = "";
        StringBuilder string = new StringBuilder();
        for (int i = 0; i < 9999; i++) {
            //string += i;
            string.append(i);
        }
        long end = System.currentTimeMillis();
        System.out.println(end - start);
    }
}
